home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 9750 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.7 KB

  1. Path: newshost.lanl.gov!tanmoy
  2. From: tanmoy@qcd.lanl.gov (Tanmoy Bhattacharya)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: Standard question - pointer initialization
  5. Date: 13 Mar 1996 04:15:25 GMT
  6. Organization: Los Alamos National Laboratory
  7. Message-ID: <TANMOY.96Mar12211525@qcd.lanl.gov>
  8. References: <4hk9un$906@hammer.msfc.nasa.gov> <4i52bk$5el@s02.pavilion.co.uk>
  9. NNTP-Posting-Host: qcd.lanl.gov
  10. Mime-Version: 1.0
  11. Content-Type: text
  12. In-reply-to: AJRobb@pavilion.co.uk's message of Tue, 12 Mar 1996 23:47:03 GMT
  13.  
  14. In article <4i52bk$5el@s02.pavilion.co.uk>
  15. AJRobb@pavilion.co.uk (Andy J Robb) writes:
  16. <snip>
  17. AJR: Off the top of my head, the only time pointers are initialized to NULL
  18. AJR: is if they are global or static.
  19.  
  20. Correct. (I mean unless explicitly initialized to NULL).
  21.  
  22. AJR: 
  23. AJR: The use of calloc() allows a list of NULL initialized pointers to be
  24. AJR: generated.  It is a good idea while code is being developed as it
  25.  
  26. Absolute nonsense. calloc generates memory initialized to all bits
  27. zero. This has no relation to null pointers except in confused ramblings.
  28.  
  29. Sorry for the strong response: I hate it when completely wrong
  30. statements, those that are contrary to explicit statements in the FAQ
  31. are delivered confidently. (And yes, I hate it when I do it too).
  32.  
  33. Cheers
  34. Tanmoy
  35. --
  36. tanmoy@qcd.lanl.gov(128.165.23.46) DECNET: BETA::"tanmoy@lanl.gov"(1.218=1242)
  37. Tanmoy Bhattacharya O:T-8(MS B285)LANL,NM87545 H:#9,3000,Trinity Drive,NM87544
  38. Others see <gopher://yaleinfo.yale.edu:7700/00/Internet-People/internet-mail>,
  39. <http://alpha.acast.nova.edu/cgi-bin/inmgq.pl>or<ftp://csd4.csd.uwm.edu/pub/
  40. internetwork-mail-guide>. -- <http://nqcd.lanl.gov/people/tanmoy/tanmoy.html>
  41. fax: 1 (505) 665 3003   voice: 1 (505) 665 4733    [ Home: 1 (505) 662 5596 ]
  42.